package cn.edu.zafu.bigdata.lhff;

class MathOperations {
    public int add(int a, int b) {
        return a + b;
    }

    public double add(double a, double b) {
        return a + b;
    }

    public int add(int a, int b, int c) {
        return a + b + c;
    }
}

public class MathOperationsTest {
    public static void main(String[] args) {
        MathOperations mathOps = new MathOperations();

        int sumInt = mathOps.add(7, 9);
        double sumDouble = mathOps.add(8.4, 10.9);
        int sumThree = mathOps.add(1, 2, 3);

        System.out.println("两个整数的和: " + sumInt);
        System.out.println("两个浮点数的和: " + sumDouble);
        System.out.println("三个整数的和: " + sumThree);
    }
}